package com.ruoyi.teaching.controller;

import com.ruoyi.common.core.web.controller.BaseController;
import com.ruoyi.common.core.web.domain.AjaxResult;
import com.ruoyi.teaching.domain.YaDailyTasks;
import com.ruoyi.teaching.service.TeachingOverviewService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/overview")
public class YaOverviewController extends BaseController {

    @Autowired
    private TeachingOverviewService teachingOverviewService;

    @GetMapping("/weekAttendance")
    public AjaxResult getWeekAttendance() {
        return AjaxResult.success(teachingOverviewService.getWeekAttendance());
    }

    @GetMapping("/interviewStatus")
    public AjaxResult getInterviewStatus() {
        return AjaxResult.success(teachingOverviewService.getInterviewStatus());
    }

    @GetMapping("/todayAttendance")
    public AjaxResult getTodayAttendance() {
        return AjaxResult.success(teachingOverviewService.getTodayAttendance());
    }

    @GetMapping("/yesterdayTasks")
    public AjaxResult getYesterdayTasks() {
        return AjaxResult.success(teachingOverviewService.getYesterdayTasks());
    }

    @GetMapping("/weekTasks")
    public AjaxResult getWeekTasks() {
        return AjaxResult.success(teachingOverviewService.getWeekTasks());
    }
}